package com.james.happyfarm.JDO;

import java.util.ArrayList;
import java.util.List;

import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

import com.james.happyfarm.PO.Friend;

@PersistenceCapable(identityType = IdentityType.APPLICATION)
public class User {

	@PrimaryKey
	@Persistent
	private String UID;
	
	@Persistent
	private String username;
	
	@Persistent
	private String password;
	
	@Persistent
	private String VERIFYCODE;
	
	@Persistent
	private String COOKIES;
	
	@Persistent
	private List<Friend> friendList = new ArrayList<Friend>();

	public List<Friend> getFriendList() {
		return friendList;
	}

	public void setFriendList(List<Friend> friendList) {
		this.friendList = friendList;
	}

	public User(String username, String password) {
		super();
		this.username = username;
		this.password = password;
	}

	public User(String uid, String username, String password,
			String verifycode, String cookies) {
		super();
		UID = uid;
		this.username = username;
		this.password = password;
		VERIFYCODE = verifycode;
		COOKIES = cookies;
	}

	public String getUID() {
		return UID;
	}

	public void setUID(String uid) {
		UID = uid;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getVERIFYCODE() {
		return VERIFYCODE;
	}

	public void setVERIFYCODE(String verifycode) {
		VERIFYCODE = verifycode;
	}

	public String getCOOKIES() {
		return COOKIES;
	}

	public void setCOOKIES(String cookies) {
		COOKIES = cookies;
	}
}
